{% extends "cab/base.html" %}
{% load snippets %}

{% block extrahead %}
{{ block.super }}
<link rel="alternate" type="application/rss+xml" title="{{cur_site.name}} latest snippets written in {{object.name}} (rss)"
 href="{% url rss_feeds "snippets" %}languages/{{object.name}}/" />
<link rel="alternate" type="application/atom+xml" title="{{cur_site.name}} latest snippets written in {{object.name}} (atom)" 
 href="{% url atom_feeds "snippets" %}languages/{{object.name}}/" />
{% endblock %}

{% block title %}All snippets written in {{ object.name }} - {{ block.super }}{% endblock %}

{% block content %}

<h1>All snippets written in <em>{{ object.name }}</em></h1>

<span id="snippet_feeds" class="feeds">
Follow:
    <a class="feedlink" href="{% url rss_feeds "snippets" %}languages/{{object.name}}/" rel="alternate"  type="application/rss+xml">
       <img class="feedicon" src="{{MEDIA_URL}}images/rss_icon.png" alt="rss icon"/>
    </a>
    <a class="feedlink" href="{% url atom_feeds "snippets" %}languages/{{object.name}}/" rel="alternate"  type="application/atom+xml">
       <img class="feedicon" src="{{MEDIA_URL}}images/atom_icon.png" alt="atom icon"/>
    </a>
</span>

{% if object_list %}
<ul>
{% for snippet in object_list %}
<li>{% show_snippet snippet %}</li>
{% endfor %}</ul>


{% paginator %}
{% else %}
<p>No snippets written in {{ object.name }} yet.</p>
{% endif %}

<p>{{ hits }} snippet{{ hits|pluralize }} {% ifequal hits 1 %}is{% else %}are{% endifequal %} written in {{ object.name }} so far.</p>

{% endblock %}